Divisor Counting Function

Definition

The divisor counting function (or just divisor function) d:Z+Z+ is a function which counts the number of positive divisors of the input.

Often this function is instead denoted by τ.


Theorem

Suppose n has unique factorisation into a product of primes p1α1pkαk. Then

d(n)=(α1+1)(αk+1).
Proof

This is a counting problem. If n=p1α1pkαk then factors are of the form p1β1pkβk where βiβj as per divisibility from unique factorisations. Each possible value of each βi defines a unique factor and for each i, βi{0,,αi} which means there are αi+1 possible values.

Hence we have

d(n)=(α1+1)(αk+1).

We can also express the divisor counting function as a Dirichlet convolution.


Multiplicativity

d is multiplicative. That is, for m,nZ with m and n coprime integers

d(mn)=d(m)d(n).
Proof

Let n=p1α1pkαk and m=q1β1qsβs. If gcd(m,n)=1, then piqj for all i,j. Therefore nm=p1α1pkαkq1β1qsβs is the unique factorisation into a product of primes without duplicate primes.

As such we have

d(nm)=d(p1α1pkαkq1β1qsβs)=(α1+1)(αk+1)(β1+1)(βs+1)=d(n)d(m).